import vuex from "vuex"
import Vue from "vue";
import createPersistedState from "vuex-persistedstate"
import user from "./user";
import tag from "./tag";
import article from "./article";

// 1.安装
Vue.use(vuex);

let store = new vuex.Store({
    modules: {
        user,
        tag,
        article
    },
    plugins:[createPersistedState({
        storage: window.sessionStorage,
    })]
});

export default store;